home *** CD-ROM | disk | FTP | other *** search
open in:
MacOS 8.1
|
Win98
|
DOS
browse contents |
view JSON data
|
view as text
This file was processed as: Mailbox/MIME Entity
(archive/mbox).
Confidence | Program | Detection | Match Type | Support
|
---|
100%
| dexvert
| Newsgroup Content (archive/news)
| magic
| Supported |
100%
| dexvert
| Mailbox/MIME Entity (archive/mbox)
| magic
| Supported |
100%
| dexvert
| Internet Message Format (text/imf)
| magic
| Supported |
1%
| dexvert
| Text File (text/txt)
| fallback
| Supported |
100%
| file
| news, ASCII text
| default
| |
100%
| checkBytes
| Printable ASCII
| default
| |
100%
| dexmagic
| PrintFox/Pagefox WEAK
| default
| |
100%
| perlTextCheck
| Likely Text (Perl)
| default
| |
100%
| siegfried
| fmt/950 MIME Email (1.0)
| default
| |
100%
| detectItEasy
| Format: plain text[LF]
| default (weak)
| |
100%
| xdgMime
| message/news
| default
|
|
hex view+--------+-------------------------+-------------------------+--------+--------+
|00000000| 50 61 74 68 3a 20 6a 75 | 70 69 74 65 72 2e 70 6c |Path: ju|piter.pl|
|00000010| 61 6e 65 74 2e 6e 65 74 | 21 75 73 65 6e 65 74 0a |anet.net|!usenet.|
|00000020| 46 72 6f 6d 3a 20 22 52 | 65 65 64 20 52 2e 20 4d |From: "R|eed R. M|
|00000030| 61 6e 67 69 6e 6f 22 20 | 3c 6d 61 6e 67 69 6e 6f |angino" |<mangino|
|00000040| 40 70 6c 61 6e 65 74 2e | 6e 65 74 3e 0a 4e 65 77 |@planet.|net>.New|
|00000050| 73 67 72 6f 75 70 73 3a | 20 63 6f 6d 70 2e 6c 61 |sgroups:| comp.la|
|00000060| 6e 67 2e 63 0a 53 75 62 | 6a 65 63 74 3a 20 52 65 |ng.c.Sub|ject: Re|
|00000070| 3a 20 57 69 65 72 64 20 | 63 6f 6e 73 74 20 70 72 |: Wierd |const pr|
|00000080| 6f 62 6c 65 6d 20 28 72 | 65 70 6f 73 74 29 0a 44 |oblem (r|epost).D|
|00000090| 61 74 65 3a 20 46 72 69 | 2c 20 32 32 20 4d 61 72 |ate: Fri|, 22 Mar|
|000000a0| 20 31 39 39 36 20 31 31 | 3a 33 32 3a 34 35 20 2d | 1996 11|:32:45 -|
|000000b0| 30 35 30 30 0a 4f 72 67 | 61 6e 69 7a 61 74 69 6f |0500.Org|anizatio|
|000000c0| 6e 3a 20 44 69 61 6c 6f | 67 69 63 20 43 6f 72 70 |n: Dialo|gic Corp|
|000000d0| 6f 72 61 74 69 6f 6e 0a | 4d 65 73 73 61 67 65 2d |oration.|Message-|
|000000e0| 49 44 3a 20 3c 33 31 35 | 32 44 36 32 44 2e 41 37 |ID: <315|2D62D.A7|
|000000f0| 31 40 70 6c 61 6e 65 74 | 2e 6e 65 74 3e 0a 52 65 |1@planet|.net>.Re|
|00000100| 66 65 72 65 6e 63 65 73 | 3a 20 3c 38 32 37 34 38 |ferences|: <82748|
|00000110| 31 33 37 37 2e 32 35 30 | 36 36 40 72 65 64 69 66 |1377.250|66@redif|
|00000120| 6f 6e 2e 64 65 6d 6f 6e | 2e 63 6f 2e 75 6b 3e 0a |on.demon|.co.uk>.|
|00000130| 4e 4e 54 50 2d 50 6f 73 | 74 69 6e 67 2d 48 6f 73 |NNTP-Pos|ting-Hos|
|00000140| 74 3a 20 73 74 61 6e 34 | 31 2e 70 6c 61 6e 65 74 |t: stan4|1.planet|
|00000150| 2e 6e 65 74 0a 4d 69 6d | 65 2d 56 65 72 73 69 6f |.net.Mim|e-Versio|
|00000160| 6e 3a 20 31 2e 30 0a 43 | 6f 6e 74 65 6e 74 2d 54 |n: 1.0.C|ontent-T|
|00000170| 79 70 65 3a 20 74 65 78 | 74 2f 70 6c 61 69 6e 3b |ype: tex|t/plain;|
|00000180| 20 63 68 61 72 73 65 74 | 3d 75 73 2d 61 73 63 69 | charset|=us-asci|
|00000190| 69 0a 43 6f 6e 74 65 6e | 74 2d 54 72 61 6e 73 66 |i.Conten|t-Transf|
|000001a0| 65 72 2d 45 6e 63 6f 64 | 69 6e 67 3a 20 37 62 69 |er-Encod|ing: 7bi|
|000001b0| 74 0a 58 2d 4d 61 69 6c | 65 72 3a 20 4d 6f 7a 69 |t.X-Mail|er: Mozi|
|000001c0| 6c 6c 61 20 32 2e 30 47 | 6f 6c 64 42 31 20 28 57 |lla 2.0G|oldB1 (W|
|000001d0| 69 6e 39 35 3b 20 49 29 | 0a 54 6f 3a 20 47 75 79 |in95; I)|.To: Guy|
|000001e0| 20 50 69 63 6b 65 72 69 | 6e 67 20 3c 67 70 40 72 | Pickeri|ng <gp@r|
|000001f0| 65 64 69 66 6f 6e 2e 64 | 65 6d 6f 6e 2e 63 6f 2e |edifon.d|emon.co.|
|00000200| 75 6b 3e 0a 0a 47 75 79 | 20 50 69 63 6b 65 72 69 |uk>..Guy| Pickeri|
|00000210| 6e 67 20 77 72 6f 74 65 | 3a 0a 3e 20 0a 3e 20 49 |ng wrote|:.> .> I|
|00000220| 66 20 49 20 64 65 63 6c | 61 72 65 20 61 20 66 75 |f I decl|are a fu|
|00000230| 6e 63 74 69 6f 6e 3a 0a | 3e 20 0a 3e 20 20 20 20 |nction:.|> .> |
|00000240| 20 20 20 20 20 76 6f 69 | 64 20 66 6f 6f 28 63 6f | voi|d foo(co|
|00000250| 6e 73 74 20 63 68 61 72 | 2a 20 73 29 0a 3e 20 0a |nst char|* s).> .|
|00000260| 3e 20 54 68 69 73 20 6d | 65 61 6e 73 20 27 73 27 |> This m|eans 's'|
|00000270| 20 69 73 20 61 20 70 6f | 69 6e 74 65 72 20 74 6f | is a po|inter to|
|00000280| 20 61 20 63 6f 6e 73 74 | 61 6e 74 20 63 68 61 72 | a const|ant char|
|00000290| 2e 20 49 2e 65 2e 20 49 | 20 70 72 6f 6d 69 73 65 |. I.e. I| promise|
|000002a0| 20 6e 6f 74 0a 3e 20 74 | 6f 20 6d 6f 64 69 66 79 | not.> t|o modify|
|000002b0| 20 27 73 27 20 69 6e 73 | 69 64 65 20 74 68 65 20 | 's' ins|ide the |
|000002c0| 66 75 6e 63 74 69 6f 6e | 2e 0a 3e 20 0a 3e 20 42 |function|..> .> B|
|000002d0| 75 74 2c 20 68 6f 77 20 | 64 6f 20 49 20 64 65 63 |ut, how |do I dec|
|000002e0| 6c 61 72 65 20 61 20 66 | 75 6e 63 74 69 6f 6e 20 |lare a f|unction |
|000002f0| 77 68 65 72 65 20 27 73 | 27 20 69 73 20 61 20 70 |where 's|' is a p|
|00000300| 6f 69 6e 74 65 72 20 74 | 6f 20 61 20 70 6f 69 6e |ointer t|o a poin|
|00000310| 74 65 72 0a 3e 20 74 6f | 20 61 20 63 6f 6e 74 73 |ter.> to| a conts|
|00000320| 74 61 6e 74 20 63 68 61 | 72 2e 20 54 68 65 20 66 |tant cha|r. The f|
|00000330| 6f 6c 6c 6f 77 69 6e 67 | 20 64 6f 65 73 6e 27 74 |ollowing| doesn't|
|00000340| 20 77 6f 72 6b 20 71 75 | 69 74 65 20 72 69 67 68 | work qu|ite righ|
|00000350| 74 3a 0a 3e 20 0a 3e 20 | 20 20 20 20 20 20 20 20 |t:.> .> | |
|00000360| 76 6f 69 64 20 66 6f 6f | 28 63 6f 6e 73 74 20 63 |void foo|(const c|
|00000370| 68 61 72 2a 2a 20 73 29 | 0a 3e 20 0a 3e 20 42 65 |har** s)|.> .> Be|
|00000380| 63 61 75 73 65 20 77 68 | 65 6e 20 49 20 74 72 79 |cause wh|en I try|
|00000390| 20 74 6f 20 70 61 73 73 | 20 61 20 27 63 68 61 72 | to pass| a 'char|
|000003a0| 2a 2a 27 20 69 6e 66 6f | 20 74 68 65 20 66 75 6e |**' info| the fun|
|000003b0| 63 74 69 6f 6e 2c 20 74 | 68 65 20 63 6f 6d 70 69 |ction, t|he compi|
|000003c0| 6c 65 72 0a 3e 20 63 6f | 6d 70 6c 61 69 6e 73 20 |ler.> co|mplains |
|000003d0| 61 62 6f 75 74 20 69 6e | 63 6f 6d 70 61 74 69 62 |about in|compatib|
|000003e0| 6c 65 20 74 79 70 65 73 | 2e 20 49 73 20 69 74 20 |le types|. Is it |
|000003f0| 74 68 61 74 20 74 68 65 | 20 63 6f 6e 73 74 20 69 |that the| const i|
|00000400| 6e 0a 3e 20 27 63 6f 6e | 73 74 20 63 68 61 72 2a |n.> 'con|st char*|
|00000410| 2a 27 20 64 6f 65 73 6e | 27 74 20 72 65 66 65 72 |*' doesn|'t refer|
|00000420| 20 74 6f 20 74 68 65 20 | 27 63 68 61 72 27 3f 20 | to the |'char'? |
|00000430| 49 66 20 73 6f 20 68 6f | 77 20 63 61 6e 20 49 20 |If so ho|w can I |
|00000440| 64 65 63 6c 61 72 65 0a | 3e 20 77 68 61 74 20 49 |declare.|> what I|
|00000450| 20 6d 65 61 6e 3f 0a 0a | 0a 47 75 79 2c 0a 0a 20 | mean?..|.Guy,.. |
|00000460| 20 54 68 69 73 20 69 73 | 20 6f 6e 65 20 6f 66 20 | This is| one of |
|00000470| 74 68 6f 73 65 20 70 72 | 6f 62 6c 65 6d 73 20 74 |those pr|oblems t|
|00000480| 68 61 74 20 64 72 69 76 | 65 20 79 6f 75 20 63 72 |hat driv|e you cr|
|00000490| 61 7a 79 21 20 20 4f 66 | 20 63 6f 75 72 73 65 20 |azy! Of| course |
|000004a0| 77 65 20 6b 6e 6f 77 20 | 74 68 61 74 20 0a 20 61 |we know |that . a|
|000004b0| 72 67 75 6d 65 6e 74 20 | 63 68 61 72 20 2a 73 20 |rgument |char *s |
|000004c0| 6d 61 74 63 68 65 73 20 | 70 61 72 61 6d 65 74 65 |matches |paramete|
|000004d0| 72 20 63 6f 6e 73 74 20 | 63 68 61 72 20 2a 70 21 |r const |char *p!|
|000004e0| 20 20 42 75 74 20 63 68 | 61 72 20 2a 2a 61 72 67 | But ch|ar **arg|
|000004f0| 76 20 64 6f 65 73 20 4e | 4f 54 20 0a 6d 61 74 63 |v does N|OT .matc|
|00000500| 68 20 70 61 72 61 6d 65 | 74 65 72 20 63 6f 6e 73 |h parame|ter cons|
|00000510| 74 20 63 68 61 72 20 2a | 2a 50 21 20 20 57 68 79 |t char *|*P! Why|
|00000520| 2c 20 49 20 68 61 76 65 | 20 61 20 62 6f 6f 6b 20 |, I have| a book |
|00000530| 69 6e 20 66 72 6f 6e 74 | 20 6f 66 20 6d 65 2c 0a |in front| of me,.|
|00000540| 5f 45 78 70 65 72 74 20 | 43 20 50 72 6f 67 72 61 |_Expert |C Progra|
|00000550| 6d 6d 69 6e 67 2c 20 44 | 65 65 70 20 53 65 63 72 |mming, D|eep Secr|
|00000560| 65 74 73 5f 2c 20 77 68 | 69 63 68 20 65 78 70 6c |ets_, wh|ich expl|
|00000570| 61 69 6e 73 20 74 68 65 | 20 61 6e 73 77 65 72 2e |ains the| answer.|
|00000580| 20 20 0a 0a 22 53 69 6e | 63 65 20 74 68 65 20 74 | .."Sin|ce the t|
|00000590| 79 70 65 73 20 63 68 61 | 72 20 2a 2a 20 61 6e 64 |ypes cha|r ** and|
|000005a0| 20 63 6f 6e 73 74 20 63 | 68 61 72 20 2a 2a 20 61 | const c|har ** a|
|000005b0| 72 65 20 62 6f 74 68 20 | 70 6f 69 6e 74 65 72 73 |re both |pointers|
|000005c0| 20 74 6f 20 75 6e 71 75 | 61 6c 69 66 69 65 64 20 | to unqu|alified |
|000005d0| 0a 74 79 70 65 73 20 74 | 68 61 74 20 61 72 65 20 |.types t|hat are |
|000005e0| 6e 6f 74 20 74 68 65 20 | 73 61 6d 65 20 74 79 70 |not the |same typ|
|000005f0| 65 2c 20 74 68 65 79 20 | 61 72 65 20 6e 6f 74 20 |e, they |are not |
|00000600| 63 6f 6d 70 61 74 69 62 | 6c 65 20 74 79 70 65 73 |compatib|le types|
|00000610| 2e 20 20 54 68 65 72 65 | 66 6f 72 65 2c 20 0a 61 |. There|fore, .a|
|00000620| 20 63 61 6c 6c 20 77 69 | 74 68 20 61 6e 20 61 72 | call wi|th an ar|
|00000630| 67 75 6d 65 6e 74 20 6f | 66 20 74 79 70 65 20 63 |gument o|f type c|
|00000640| 68 61 72 20 2a 2a 20 63 | 6f 72 72 65 73 70 6f 6e |har ** c|orrespon|
|00000650| 64 69 6e 67 20 74 6f 20 | 61 20 70 61 72 61 6d 65 |ding to |a parame|
|00000660| 74 65 72 20 6f 66 20 74 | 79 70 65 20 0a 63 6f 6e |ter of t|ype .con|
|00000670| 73 74 20 63 68 61 72 20 | 2a 2a 20 69 73 20 6e 6f |st char |** is no|
|00000680| 74 20 61 6c 6c 6f 77 65 | 64 2e 0a 0a 49 20 64 6f |t allowe|d...I do|
|00000690| 6e 27 74 20 6b 6e 6f 77 | 20 69 66 20 49 20 75 6e |n't know| if I un|
|000006a0| 64 65 72 73 74 61 6e 64 | 20 74 68 61 74 20 66 75 |derstand| that fu|
|000006b0| 6c 6c 79 2c 20 62 75 74 | 20 74 68 65 72 65 20 49 |lly, but| there I|
|000006c0| 53 20 61 6e 20 61 6e 73 | 77 65 72 21 20 3a 29 0a |S an ans|wer! :).|
|000006d0| 0a 52 65 65 64 0a 2d 2d | 20 0a 20 20 20 20 5f 5f |.Reed.--| . __|
|000006e0| 5f 5f 5f 5f 5f 5f 5f 5f | 5f 5f 5f 5f 5f 5f 5f 5f |________|________|
|000006f0| 5f 5f 5f 5f 5f 5f 5f 5f | 5f 5f 5f 5f 5f 5f 5f 5f |________|________|
|00000700| 5f 5f 5f 5f 5f 5f 5f 5f | 5f 5f 5f 5f 5f 5f 5f 5f |________|________|
|00000710| 5f 5f 0a 20 20 20 20 5c | 52 65 65 64 20 52 2e 20 |__. \|Reed R. |
|00000720| 4d 61 6e 67 69 6e 6f 20 | 20 20 20 20 5c 20 20 2a |Mangino | \ *|
|00000730| 2a 20 44 69 61 6c 6f 67 | 69 63 20 43 6f 72 70 6f |* Dialog|ic Corpo|
|00000740| 72 61 74 69 6f 6e 20 2a | 2a 20 20 5c 0a 20 20 20 |ration *|* \. |
|00000750| 20 2f 20 6d 61 6e 67 69 | 6e 6f 40 70 6c 61 6e 65 | / mangi|no@plane|
|00000760| 74 2e 6e 65 74 20 2f 20 | 57 6f 72 6c 64 20 6c 65 |t.net / |World le|
|00000770| 61 64 65 72 20 69 6e 20 | 74 68 65 20 64 65 73 69 |ader in |the desi|
|00000780| 67 6e 20 6f 66 2f 0a 20 | 20 20 20 5c 20 74 6f 72 |gn of/. | \ tor|
|00000790| 6e 61 64 6f 40 65 73 75 | 2e 65 64 75 20 20 20 20 |nado@esu|.edu |
|000007a0| 5c 20 20 63 6f 6d 70 75 | 74 65 72 20 74 65 6c 65 |\ compu|ter tele|
|000007b0| 70 68 6f 6e 79 20 73 79 | 73 74 65 6d 73 20 20 5c |phony sy|stems \|
|000007c0| 0a | |. | |
+--------+-------------------------+-------------------------+--------+--------+